package zut.edu.cs.network.mytest;

import java.util.Calendar;
import java.util.Date;

public class MyDateTest {

	public static void main(String[] args) {
/*//		获取当前系统的时间
		Date date = new Date();
		System.out.println(date);
//		设置时间
		Date date2 = new Date(2018-1900, 9, 30);
		System.out.println(date2);
		System.out.println((date.getYear()+1900)+"年"+(date.getMonth()+1)+"月"+date.getDate());
		System.out.println(date.getDay());*/
		
		Calendar calendar =Calendar.getInstance();
//		设置时间
		calendar.set(2018, 9, 30);
		System.out.println(calendar.getWeekYear());
		calendar.add(calendar.YEAR, 1);
		System.out.println(calendar.getWeekYear());
	}

}
